Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(button): update Button story and documentation #6565

Merged
merged 12 commits into from
Aug 13, 2020

Conversation

tw15egan
Copy link
Member

@tw15egan tw15egan commented Jul 27, 2020

Closes #6564

Updates Button to new CSF format and adds in prop documentation

Done

  • Update to CSF
  • Create Button.mdx and fill out with template
  • Document any discrepancies for v11

Changelog

New

  • Added react/sort-prop-types as a warning so that our PropType definitions are in alphabetical order. THat way the Prop tables will also be in alphabetical order.
  • Docs tab now includes detailed descriptions of each prop as well as examples and code snippets
  • Set default prop values for tooltipAlignment and tooltipPosition so icon-only-buttons require two less props to be specified by default.

Changed

  • Sorted PropType definitions alphabetically

Testing / Reviewing

Check updated docs for grammar usage and that the examples look correct

Questions for reviewers:

  • is the set of buttons story is still up-to-date?
  • Any other examples we want to show?

Issues for V11

  • Button skeleton uses deprecated small instead of size

@netlify
Copy link

netlify bot commented Jul 27, 2020

Deploy preview for carbon-elements ready!

Built with commit d966825

https://deploy-preview-6565--carbon-elements.netlify.app

@netlify
Copy link

netlify bot commented Jul 27, 2020

Deploy preview for carbon-components-react ready!

Built with commit d966825

https://deploy-preview-6565--carbon-components-react.netlify.app

@tw15egan
Copy link
Member Author

tw15egan commented Jul 30, 2020

@joshblack question about knobs: are we removing them in favor of showing all examples in the docs? Ran into some issues trying to get the IconOnly button to render due to the knobs. Also, the Show Code is not super helpful since it just shows {...props.iconOnly()}

Also wondering if we should just focus on the props + usage in the docs, rather than "patterns". In this case, the Set of Buttons pattern doesn't seem too helpful and has no props specific to that variation.

@tw15egan tw15egan marked this pull request as ready for review August 4, 2020 23:02
@tw15egan tw15egan requested a review from a team as a code owner August 4, 2020 23:02
@tw15egan tw15egan requested a review from a team as a code owner August 4, 2020 23:43
@andreancardona andreancardona self-assigned this Aug 6, 2020
@tw15egan
Copy link
Member Author

@andreancardona I just updated this to match the epic / other docs PR's - mainly just removed some extra stories, and put each variation as it's own story.

@andreancardona
Copy link
Contributor

ther docs PR'

Looks good! @tw15egan does percy need to pass?

@tw15egan
Copy link
Member Author

@andreancardona approved them, differences were due to changing the stories to show the variants vs the old patterns

@andreancardona
Copy link
Contributor

@andreancardona approved them, differences were due to changing the stories to show the variants vs the old patterns

sounds good :)

@alisonjoseph
Copy link
Member

Looks like some conflicts because the new ButtonSet component got merged in

@tw15egan
Copy link
Member Author

@alisonjoseph should be good now 👍

@kodiakhq kodiakhq bot merged commit 6859904 into carbon-design-system:master Aug 13, 2020
@tw15egan tw15egan deleted the update-button-docs branch April 28, 2021 18:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update the code documentation for Button
5 participants